<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<meta charset="utf-8">
<head th:include="include :: header"></head>
<body class="childrenBody">
	<form class="layui-form" style="width:80%;margin-top: 10px">
		<input name="deptId"  type="hidden" id="treeId"/>
		<div class="layui-form-item layui-row layui-col-xs12">
			<label class="layui-form-label">登录名称</label>
			<div class="layui-input-block">
				<input type="text" name="loginName" class="layui-input loginName" lay-verify="required" placeholder="请输入登录名称">
			</div>
		</div>
		<div class="layui-form-item layui-row layui-col-xs12">
			<label class="layui-form-label">用户名称</label>
			<div class="layui-input-block">
				<input type="text" name="userName" class="layui-input userName" lay-verify="required" placeholder="请输入用户名称">
			</div>
		</div>
		<div class="layui-form-item layui-row layui-col-xs12">
			<label class="layui-form-label">部门名称</label>
			<div class="layui-input-block">
				<input type="text" name="deptName" id="treeName" readonly="readonly" class="layui-input deptName" lay-verify="required">
			</div>
		</div>
		<div class="layui-form-item layui-row layui-col-xs12">
			<label class="layui-form-label">密码</label>
			<div class="layui-input-block">
				<input type="password" name="password" class="layui-input password" lay-verify="required" placeholder="请输入密码">
			</div>
		</div>
		<div class="layui-form-item layui-row layui-col-xs12">
			<label class="layui-form-label">邮箱</label>
			<div class="layui-input-block">
				<input type="email" name="email" class="layui-input email" lay-verify="email" placeholder="请输入邮箱">
			</div>
		</div>
		<div class="layui-form-item layui-row layui-col-xs12">
			<label class="layui-form-label">手机</label>
			<div class="layui-input-block">
				<input type="number" name="phonenumber" class="layui-input phonenumber" lay-verify="phone" placeholder="请输入手机">
			</div>
		</div>
		<div class="layui-form-item layui-row layui-col-xs12" th:with="type=${@dict.getType('sys_user_sex')}">
			<label class="layui-form-label">性别</label>
			<div class="layui-input-block userSex">
				<input th:each="dict : ${type}" type="radio" class="sex" name="sex" th:value="${dict.dictValue}" th:title="${dict.dictLabel}">
			</div>
		</div>
		<div class="layui-form-item layui-row layui-col-xs12">
			<label class="layui-form-label">角色:</label>
			<div class="layui-input-block">
				<input th:each="role:${roles}" type="checkbox" class="role" name="role" th:title="${role.roleName}" lay-skin="primary" th:value="${role.roleId}">
			</div>
		</div>
		<div class="layui-form-item layui-row layui-col-xs12">
			<div class="layui-input-block">
				<button class="layui-btn " lay-submit="" lay-filter="addUser">立即添加</button>
				<button type="button" class="layui-btn  layui-btn-primary close">取消</button>
			</div>
		</div>
	</form>
	<div th:include="include::footer"></div>
	<script th:src="@{/js/user/adduser.js}"></script>
</body>
</html>